From ea5f16fd2d5e1f9b14290c6d0eae3df092276d01 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Thu, 29 Oct 2015 07:43:30 -0400 Subject: [PATCH] searchbar: Add an element name to the css node This lets us avoid hardcoding the type in CSS. --- gtk/gtksearchbar.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gtk/gtksearchbar.c b/gtk/gtksearchbar.c index 97d48d153a..8833fee399 100644 --- a/gtk/gtksearchbar.c +++ b/gtk/gtksearchbar.c @@ -56,6 +56,10 @@ * The following example shows you how to create a more complex search * entry. * + * # CSS nodes + * + * GtkSearchBar has a single CSS node with name searchbar. + * * ## Creating a search bar * * [A simple example](https://git.gnome.org/browse/gtk+/tree/examples/search-bar.c) @@ -421,6 +425,8 @@ gtk_search_bar_class_init (GtkSearchBarClass *klass) gtk_widget_class_bind_template_child_internal_private (widget_class, GtkSearchBar, revealer); gtk_widget_class_bind_template_child_internal_private (widget_class, GtkSearchBar, box_center); gtk_widget_class_bind_template_child_internal_private (widget_class, GtkSearchBar, close_button); + + gtk_widget_class_set_css_name (widget_class, "searchbar"); } static void -- 2.30.2